AccountViewModel

class AccountViewModel @Inject constructor(userRepository: UserRepository, accountService: AccountService) : ViewModel

ViewModel responsible for managing user account state and authentication status. It listens for authentication state changes and provides relevant user data.

Constructors

Link copied to clipboard
@Inject
constructor(userRepository: UserRepository, accountService: AccountService)

Properties

Link copied to clipboard
val uiState: StateFlow<AccountUiState>

Functions

Link copied to clipboard
open fun addCloseable(closeable: AutoCloseable)
fun addCloseable(key: String, closeable: AutoCloseable)
Link copied to clipboard
Link copied to clipboard
fun signOut(onResult: () -> Unit)

Signs the user out and updates the UI state accordingly.